package cn.ylz.ylmall.product.dao.persist.mapper;

import cn.ylz.ylmall.product.pojo.entity.PComment;
import cn.ylz.ylmall.product.pojo.vo.PCommentStandardVO;
import cn.ylz.ylmall.product.pojo.vo.PCommentVO;
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import org.springframework.stereotype.Repository;

import java.util.List;

@Repository
public interface PCommentMapper extends BaseMapper<PComment> {

    List<PCommentVO> listRootComment(Long id);

    List<PCommentVO> listByParentId(Long commentId);

    PCommentStandardVO getStandardById(Long commentId);

    List<Long> getLikedCommentsByUserAndProduct(Long productId, Long userId);
}
